import Page from "@/components/Page";
import { defineComponent } from "vue";
import style from "./index.module.less";
export default defineComponent({
  props: {
    data: {
      type: Array,
      default: [],
    },
  },
  setup(props, { slots }) {
    return () => (
      <div class={["font--t2"]}>
        <div class={[style["title"]]}>
          {props.data?.map((item: any) => (
            <div
              style={{ color: "#666666" }}
              class="flex items-center justify-between"
            >
              <div>
                <span>{item.name}</span>
                <span class={["ml-5"]}>{item.value}</span>
              </div>
              <div> {item.right && item.right()}</div>
            </div>
          ))}
        </div>
        {slots.right?.()}
      </div>
    );
  },
});
